package com.springboot.demo.entity.po;

import com.baomidou.mybatisplus.annotation.TableField;
import com.springboot.demo.entity.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import javax.persistence.Table;
import javax.persistence.Transient;
import java.io.Serializable;
import java.util.List;


/**
* 字典信息表
* <p>
* Created 2021/04/08.
*
* @author huangpp
*/
@Data
@Accessors(chain=true)
@Table(name = "SYS_CODE")
@EqualsAndHashCode(callSuper = false)
@ApiModel(value = "SysCode", description = "字典信息表")
public class SysCode extends BaseEntity  implements Serializable {

    private static final long serialVersionUID = 1L;

    /** 定数区分 */
    @ApiModelProperty("定数区分")
    private String dictCode;
    /** 父节点id */
    @ApiModelProperty("父节点id")
    private Long parentId;
    /** 定数值 */
    @ApiModelProperty("定数值")
    private String code;
    /** 定数值名称 */
    @ApiModelProperty("定数值名称")
    private String name;
    /** 排序 */
    @ApiModelProperty("排序")
    private String sort;
    /** 是否调整 */
    @ApiModelProperty("是否调整")
    private String canModify;

    @TableField(exist = false)
    @Transient
    private String parentName;

    /** 子级数据 */
    @TableField(exist = false)
    @Transient
    private List<SysCode> list;
}
